﻿using System;
using System.Collections.Generic;
//using System.Linq;
using System.Web;

/// <summary>
/// Summary description for SkyscannerDataInfo
/// </summary>
namespace CE.Skyscanner
{
    public class SkyscannerDataInfo
    {
        public SkyscannerDataInfo()
        {
            //
            // TODO: Add constructor logic here
            //
        }
        public string SessionKey { get; set; }
        public Query Query { get; set; }
        public string Status { get; set; }
        public List<Itineraries> Itineraries { get; set; }
        public List<Legs> Legs { get; set; }
        public List<Carriers> Carriers { get; set; }
        public List<Agents> Agents { get; set; }
        public List<Places> Places { get; set; }
        public List<Currencies> Currencies { get; set; }
    }

    public class Query
    {
        public string Country { get; set; }
        public string Currency { get; set; }
        public string Locale { get; set; }
        public int Adults { get; set; }
        public int Children { get; set; }
        public int Infants { get; set; }
        public int OriginPlace { get; set; }
        public int DestinationPlace { get; set; }
        public DateTime OutBoundDate { get; set; }
        public DateTime InboundDate { get; set; }
        public string LocationSchema { get; set; }
        public string CabinClass { get; set; }
    }

    public class Itineraries
    {
        public string OutboundLegId { get; set; }
        public string InboundLegId { get; set; }
        public List<PricingOptions> PricingOptions { get; set; }
        public BookingDetailsLink BookingDetailsLink { get; set; }
    }

    public class PricingOptions
    {
        public List<int> Agents { get; set; }
        public int QuoteAgeInMinutes { get; set; }
        public double Price { get; set; }
    }

    public class BookingDetailsLink
    {
        public string Uri { get; set; }
        public string Body { get; set; }
        public string Method { get; set; }
    }

    public class Legs
    {
        public string Id { get; set; }
        public int OriginStation { get; set; }
        public int DestinationStation { get; set; }
        public DateTime Departure { get; set; }
        public DateTime Arrival { get; set; }
        public int Duration { get; set; }
        public string JourneyMode { get; set; }
        public List<int> Stops { get; set; }
        public List<int> Carriers { get; set; }
        public List<int> OperatingCarriers { get; set; }
        public string Directionality { get; set; }
    }

    public class Carriers
    {
        public int Id { get; set; }
        public string Code { get; set; }
        public string Name { get; set; }
        public string ImageUrl { get; set; }
    }

    public class Agents
    {
        public int Id { get; set; }
        public string Name { get; set; }
        public string ImageUrl { get; set; }
        public string Status { get; set; }
        public bool OptimisedForMobile { get; set; }
        public string BookingNumber { get; set; }
        public string Type { get; set; }
    }

    public class Places
    {
        public int Id { get; set; }
        public int ParentId { get; set; }
        public string Code { get; set; }
        public string Type { get; set; }
        public string Name { get; set; }
    }

    public class Currencies
    {
        public string Code { get; set; }
        public string Symbol { get; set; }
        public string ThousandsSeparator { get; set; }
        public string DecimalSeparator { get; set; }
        public bool SymbolOnLeft { get; set; }
        public bool SpaceBetweenAmountAndSymbol { get; set; }
        public int RoundingCoefficient { get; set; }
        public int DecimalDigits { get; set; }
    }
}